﻿using Volo.Abp.Ui.Branding;
using Volo.Abp.DependencyInjection;
using Volo.Abp.MultiTenancy;
using System;

namespace SanJ.FreeCare.Web;

[Dependency(ReplaceServices = true)]
public class FreeCareBrandingProvider : DefaultBrandingProvider
{
    private string brandName { get; set; }
    private CurrentTenant CurrentTenant;
    //public override string AppName => "医院";
    public override string AppName => brandName;
    public FreeCareBrandingProvider(CurrentTenant currentTenant)
    {
        CurrentTenant = currentTenant;
        if (CurrentTenant.Name.IsNullOrEmpty())
        {
            brandName = "三京医院";
        }
        else
        {
            brandName = CurrentTenant.Name;
        }
    }
}
